Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Onboarding] [Stack] Add Onboarding experience into Stack #204351

Open
wants to merge 42 commits into
base: main
Choose a base branch
from

Conversation

joemcelroy
Copy link
Member

@joemcelroy joemcelroy commented Dec 16, 2024

Summary

TODO

  • FTR - solution navigation ftr - add test for index management
  • FTR - fix the index management index list page test to navigate through the solution navigation to index management list page
  • code - playground create index action needs to check if part of es solution navigation
  • Unit - add unit for index management with the change for solution navigation
  • Unit - Fix any failures in index management tests
  • Fix FTR tests

These changes are only targeting 9.0.

Checklist

Check the PR satisfies following conditions.

Reviewers should verify this PR satisfies this list as well.

  • Any text added follows EUI's writing guidelines, uses sentence case text and includes i18n support
  • Documentation was added for features that require explanation or tutorials
  • Unit or functional tests were updated or added to match the most common scenarios
  • If a plugin configuration key changed, check if it needs to be allowlisted in the cloud and added to the docker list
  • This was checked for breaking HTTP API changes, and any breaking changes have been approved by the breaking-change committee. The release_note:breaking label should be applied in these situations.
  • Flaky Test Runner was used on any tests changed
  • The PR description includes the appropriate Release Notes section, and the correct release_note:* label is applied per the guidelines

@joemcelroy joemcelroy added release_note:skip Skip the PR/issue when compiling release notes Team:Search backport:skip This commit does not require backporting labels Dec 16, 2024
kibanamachine and others added 22 commits December 16, 2024 10:37
@yansavitski yansavitski force-pushed the onboarding-stack-add-plugin branch from cb0210a to af6b879 Compare December 27, 2024 20:14
@yansavitski yansavitski force-pushed the onboarding-stack-add-plugin branch from 24542e5 to 735e3b5 Compare January 5, 2025 22:40
@yansavitski yansavitski force-pushed the onboarding-stack-add-plugin branch from 2a9efd9 to a6f3b8f Compare January 6, 2025 14:38
@yansavitski yansavitski force-pushed the onboarding-stack-add-plugin branch from 8a5eea6 to 1df4762 Compare January 6, 2025 21:43
@elasticmachine
Copy link
Contributor

⏳ Build in-progress, with failures

Failed CI Steps

Test Failures

  • [job] [logs] FTR Configs #7 / X-Pack Accessibility Tests - Group 1 Management index management indices indices with data index details index details - settings
  • [job] [logs] FTR Configs #7 / X-Pack Accessibility Tests - Group 1 Management index management indices indices with data index details index details - settings

History

@yansavitski yansavitski marked this pull request as ready for review January 7, 2025 16:21
@yansavitski yansavitski requested review from a team as code owners January 7, 2025 16:21
@yansavitski yansavitski enabled auto-merge (squash) January 7, 2025 16:30
Copy link
Member

@sabarasaba sabarasaba left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for working on this @joemcelroy! Had an initial pass at the code and looks good, just have few questions about these two tests

@@ -18,14 +18,14 @@ export default ({ getPageObjects, getService }: FtrProviderContext) => {
await pageObjects.common.navigateToApp('indexManagement');
});

it('Navigates to the index details page from the home page', async () => {
it.skip('Navigates to the index details page from the home page', async () => {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did this break because of the changes or is it still wip? It seems like an important test to have

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It constantly breaks because it can't load indexManagement page and supposed to be fixed in future tickets

image

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@saarikabhasi 's Index Details locator PR will fix this, and it may merge first. but either way lets make sure this doesn't stay skipped.

Comment on lines -91 to -92
await pageObjects.indexManagement.performIndexAction('flush');
await testSubjects.click('indexDetailsBackToIndicesButton');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just for my own understanding, why are these actions not needed anymore?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

New searchIndex page has not flush function anymore :(

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we shouldn't be updating these tests.

These should still be using the index management details page. But that will likely be handled by @saarikabhasi PR.

@@ -17,7 +17,7 @@ import { NewSearchIndexTemplate } from '../new_search_index_template';

import { MethodApi } from './method_api';

describe('MethodApi', () => {
describe.skip('MethodApi', () => {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whats going on here, why are we skipping this?

@@ -49,7 +49,7 @@ export const buildBaseClassicNavItems = (): ClassicNavItem[] => {
{
'data-test-subj': 'searchSideNav-Indices',
deepLink: {
link: 'enterpriseSearchContent:searchIndices',
link: 'management:index_management',
shouldShowActiveForSubroutes: true,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can remove this, when you navigate to index management with classic nav you'll get a different page side nav.

Suggested change
shouldShowActiveForSubroutes: true,

@@ -152,9 +148,9 @@ const mockNavLinks = [
url: '/app/elasticsearch/overview',
},
{
id: 'enterpriseSearchContent:searchIndices',
id: 'management:index_management',
title: 'Indices',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Update this mock with the title for management:index_management (Index Management I think) so these test reflect reality.

OR we could override the title by setting a name: property for this link in base_nav so that it stays Indices. But I think we wanted to show Index Management for both classic and solution navs now. Confirm that and match the two links.

@@ -116,27 +115,21 @@ export const getNavigationTreeDefinition = ({
{
children: [
{
title: i18n.translate('xpack.enterpriseSearch.searchNav.kibana.indices', {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See other comment, we can either remove this title, to take the title from the management:index_management deeplink or we should override the title in base_nav.tsx to match this.

prepend('/app/management/data/index_management/')
) ||
pathNameSerialized.startsWith(prepend('/app/elasticsearch/indices')) ||
pathNameSerialized.startsWith(prepend('/app/elasticsearch/start'))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For stack '/app/elasticsearch/start' is going to be active for Overview instead of Index Management so we'll want to remove this line. But I that can be done in the redirect PR @yansavitski is working on now.

}
return null;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we need to useMemo this with a single locator. we can create a callback for the onClick event handler since it will only be used if the locator exists.

await a11y.testAppSnapshot();
});

it('index details - settings', async () => {
await PageObjects.indexManagement.clickIndexDetailsTab('settings');
await PageObjects.searchIndexDetail.changeTab('settingsTab');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we update the tab key to be just settings and not settingsTab ? (not required for this PR, but something we should note)

@@ -18,14 +18,14 @@ export default ({ getPageObjects, getService }: FtrProviderContext) => {
await pageObjects.common.navigateToApp('indexManagement');
});

it('Navigates to the index details page from the home page', async () => {
it.skip('Navigates to the index details page from the home page', async () => {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@saarikabhasi 's Index Details locator PR will fix this, and it may merge first. but either way lets make sure this doesn't stay skipped.

Comment on lines -91 to -92
await pageObjects.indexManagement.performIndexAction('flush');
await testSubjects.click('indexDetailsBackToIndicesButton');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we shouldn't be updating these tests.

These should still be using the index management details page. But that will likely be handled by @saarikabhasi PR.

@@ -82,9 +82,6 @@ export function IndexManagementPageProvider({ getService }: FtrProviderContext)
async clickIndexAt(indexOfRow: number): Promise<void> {
const indexList = await testSubjects.findAll('indexTableIndexNameLink');
await indexList[indexOfRow].click();
await retry.waitFor('details page title to show up', async () => {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we should not change this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting release_note:skip Skip the PR/issue when compiling release notes Team:Search
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants